{
    "cells": [
        {
            "cell_type": "code",
            "execution_count": 1,
            "source": [
                "import numpy as np\r\n",
                "# ndarray 对象\r\n",
                "arr = np.array([[1,2,3],[4,5,6],[7,8,9]])\r\n",
                "print(arr)\r\n"
            ],
            "outputs": [
                {
                    "output_type": "stream",
                    "name": "stdout",
                    "text": [
                        "[[1 2 3]\n",
                        " [4 5 6]\n",
                        " [7 8 9]]\n"
                    ]
                }
            ],
            "metadata": {}
        },
        {
            "cell_type": "code",
            "execution_count": 19,
            "source": [
                "import numpy as np\r\n",
                "# 结构数组\r\n",
                "student = np.dtype({'names':['name','english','math'],\r\n",
                "'formats':['U','i','f']})\r\n",
                "sd = np.array([(u'小张',100,99),('小李',100,98),('小王',100,100),('小赵',90,92)],dtype=student)\r\n",
                "print(sd)\r\n",
                "\r\n"
            ],
            "outputs": [
                {
                    "output_type": "stream",
                    "name": "stdout",
                    "text": [
                        "[('', 100,  99.) ('', 100,  98.) ('', 100, 100.) ('',  90,  92.)]\n"
                    ]
                }
            ],
            "metadata": {}
        },
        {
            "cell_type": "code",
            "execution_count": null,
            "source": [
                "from pandas import Series,DataFrame"
            ],
            "outputs": [],
            "metadata": {}
        }
    ],
    "metadata": {
        "orig_nbformat": 4,
        "language_info": {
            "name": "python",
            "version": "3.8.3",
            "mimetype": "text/x-python",
            "codemirror_mode": {
                "name": "ipython",
                "version": 3
            },
            "pygments_lexer": "ipython3",
            "nbconvert_exporter": "python",
            "file_extension": ".py"
        },
        "kernelspec": {
            "name": "python3",
            "display_name": "Python 3.8.3 64-bit ('base': conda)"
        },
        "interpreter": {
            "hash": "4905652b14e4b7eb92899b78ac499a22c488804455b27940a322fd82aaf71031"
        }
    },
    "nbformat": 4,
    "nbformat_minor": 2
}